package com.peanut.baby.mvp.search;

import com.peanut.baby.model.LiveRoom;
import com.peanut.baby.model.QA;
import com.peanut.baby.model.SearchResultBundle;
import com.peanut.baby.model.SearchResultItem;
import com.peanut.baby.mvp.BasePresenter;
import com.peanut.baby.mvp.BaseView;

import java.util.List;

/**
 * Created by anonymouslystudio on 2017/8/14.
 */

public interface SearchContract {
    interface View extends BaseView{
//        void onSearchResultGet(List<QA> results);
//        void onRequestFailed(String reason);
//        void onPraiseSuccess(QA qa);
//        void onPraiseFailed(String reason);
        void onSearchResultGet(boolean success, List<SearchResultItem> items, SearchResultBundle orgData, String failReason);
        void onPraiseResult(boolean success, QA qa, String failReason);
        void onJoinResult(boolean success, LiveRoom room, String failReason);
    }

    interface Presenter extends BasePresenter{
//        void searchQa(int pageNo,int pageSize,String keyword);
        void praiseQA(QA qa);
        void search(String text);
        void joinRoom(LiveRoom room);
    }
}
